<%-- 
    Document   : login
    Created on : 2008-7-21, 18:30:48
    Author     : Administrator
--%>

<%@page pageEncoding="UTF-8"%>
<%@ page import="sunsite.tools.*" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Login</title>
        <%  String serverPath = Path.getServerUrl(request);%>
        <link rel="stylesheet" type="text/css" href="<%=serverPath%>ExtJs/resources/css/ext-all.css" />
        <script type="text/javascript" src="<%=serverPath%>ExtJs/adapter/ext/ext-base.js"></script>
        <script type="text/javascript" src="<%=serverPath%>ExtJs/ext-all.js"></script>
        <script type="text/javascript" src="<%=serverPath%>js/user.js"></script>
        <script type="text/javascript" src="<%=serverPath%>js/tools.js"></script>
    </head>
    <body>
        <s:if test="#session.userSession == null">
            <input type="button" id="loginBtn" value="Login" onclick="showLoginDialog('verifyCodeImageLogin','<%=serverPath%>');"/>
            <div id="showUser"></div>
        </s:if>
        <s:else>
            Welcome, ${sessionScope.userSession.userName}
        </s:else>
        <div id="divLoginWindow" style="display:none; ">
            <div id="divLoginInfo">
                <table id="tableLogin2" align="center" cellspacing="7px">
                    <tr>
                        <td align="right"><font size="2" >用户名</font></td>
                        <td align="left"><input id="userName" type="text" class="textbox" size="16" maxlength="20"></td>
                    </tr>
                    <tr>
                        <td align="right"><font size="2" >密码</font></td>
                        <td align="left"><input id="password" type="password" class="textbox" size="16" maxlength="20"></td>
                    </tr>
                    <tr>
                        <td align="right"><font size="2" >验证码</font></td>
                        <td align="left"><input id="verifyCode" type="text" class="textbox" maxlength="6" size="4">
                    </tr>
                    <tr>
                        <td></td>
                        <td align="left"><img id="verifyCodeImageLogin" src='<%=serverPath%>tools/verifyCode.jsp?width=80&heigth=24'/>
                        <a href="#" onclick='return getVerifyCode("verifyCodeImageLogin","<%=serverPath%>");'><font size="2" > 刷新</font></a></td>
                    </tr>
                </table>
            </div>
        </div>

        <!--用于输出消息-->
        <div id="divMessageTipLogin"></div>
    </body>
</html>
